import React from 'react';
import ReactDOM from 'react-dom/client';
import {BrowserRouter} from 'react-router-dom'
import App from './App';
import store from './store/store';


const root = ReactDOM.createRoot(document.getElementById('root'));
//把整个App中的组件放在一个路由器中,我们使用的是</BrowserRouter>
root.render(
   // <React.StrictMode>
   <BrowserRouter>
     <App />
   </BrowserRouter>
 
   // </React.StrictMode>
);
store.subscribe(()=>{
  root.render(<App />);
})


